<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>个人中心 - 智淘GO</title>
    <!-- Bootstrap 5 CSS -->
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.3.0/css/bootstrap.min.css" rel="stylesheet">
    <style>
        body {
            background: url('https://pic2.zhimg.com/v2-86ffa1ad12c00587d5cb6f9bd362578a_r.jpg?source=1940ef5c') no-repeat center center fixed;
            background-size: cover;
            font-family: 'Arial', sans-serif;
        }
        .profile-card {
            background: rgba(255, 255, 255, 0.9);
            border-radius: 15px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
            padding: 2rem;
            margin-top: 2rem;
        }
        .section-title {
            color: #e67e22;
            border-bottom: 2px solid #e67e22;
            padding-bottom: 0.5rem;
            margin-bottom: 1.5rem;
            font-weight: bold;
        }
        .info-item {
            margin-bottom: 1.2rem;
            padding: 1rem 1.5rem;
            background: rgba(255, 255, 255, 0.95);
            border-radius: 8px;
            transition: all 0.3s ease;
            border: 1px solid rgba(230, 126, 34, 0.1);
        }
        .info-item:hover {
            transform: translateX(10px);
            box-shadow: 0 4px 12px rgba(230, 126, 34, 0.2);
        }
        .edit-btn {
            background: linear-gradient(135deg, #e67e22, #d35400);
            color: white;
            padding: 10px 30px;
            border-radius: 25px;
            border: none;
            transition: all 0.3s ease;
            font-weight: bold;
        }
        .edit-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(230, 126, 34, 0.4);
        }
        .navbar {
            background: rgba(230, 126, 34, 0.9) !important;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        }
        .navbar-brand, .nav-link {
            color: white !important;
        }
        .nav-link:hover {
            color: #f8c291 !important;
        }
        .btn-outline-primary {
            border-color: #e67e22;
            color: #e67e22;
        }
        .btn-outline-primary:hover {
            background: #e67e22;
            color: white;
        }
    </style>
</head>
<body>
    <!-- 导航栏 -->
    <nav class="navbar navbar-expand-lg navbar-dark mb-4">
        <div class="container">
            <a class="navbar-brand" href="#">智淘GO</a>
            <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav">
                <span class="navbar-toggler-icon"></span>
            </button>
            <div class="collapse navbar-collapse" id="navbarNav">
                <ul class="navbar-nav ms-auto">
                    <li class="nav-item">
                        <a class="nav-link" href="{% url 'index' %}">首页</a>
                    </li>
                </ul>
            </div>
        </div>
    </nav>

    <!-- 主要内容 -->
    <div class="container">
        <div class="row justify-content-center">
            <div class="col-lg-8">
                <div class="profile-card">
                    <!-- 个人信息区块 -->
                    <h2 class="section-title mb-4">个人信息</h2>

                    <div class="info-item">
                        <div class="row">
                            <div class="col-md-4 fw-bold">学号</div>
                            <div class="col-md-8">{{ profile.student_id }}</div>
                        </div>
                    </div>

                    <div class="info-item">
                        <div class="row">
                            <div class="col-md-4 fw-bold">用户姓名</div>
                            <div class="col-md-8">{{ user.username }}</div>
                        </div>
                    </div>

                    <div class="info-item">
                        <div class="row">
                            <div class="col-md-4 fw-bold">手机号码</div>
                            <div class="col-md-8">{{ profile.mobile }}</div>
                        </div>
                    </div>

                    <div class="info-item">
                        <div class="row">
                            <div class="col-md-4 fw-bold">性别</div>
                            <div class="col-md-8">{{ profile.get_gender_display }}</div>
                        </div>
                    </div>

                    <div class="info-item">
                        <div class="row">
                            <div class="col-md-4 fw-bold">邮箱</div>
                            <div class="col-md-8">
                                {{ user.email }}
                                <a href="#" class="btn btn-sm btn-outline-primary ms-2">修改邮箱</a>
                            </div>
                        </div>
                    </div>

                    <div class="text-center mt-4">
                        <a href="{% url 'profile_edit' %}" class="edit-btn">编辑个人信息</a>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <!-- Bootstrap 5 JS -->
    <script src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.3.0/js/bootstrap.bundle.min.js"></script>
</body>
</html>